<?php
  class Menu extends Component {
    private $items = array();
    function setItems($items) {
        $this->items = $items;
    }
    function show($id) {
      $html = "";
      foreach($this->items as $item) {
          $html .= "<span style=\"padding: 0 9px; color: #bbbbbb;\" onclick=\"send_event(\\'" . $this->uuid . "\\',\\'" . $item . "\\',true);\">" . $item . "</span>"; 
      }  
      parent::show($id,$html);
       
    }
    function __construct($uuid) {
      parent::__construct($uuid);
      $this->setBounds(0,0,100,24);
      $this->setStyle("background", "#2d2d2d");
      $this->setStyle("fontFamily","Arial, sans-serif");
      $this->setStyle("fontSize","13px");
      $this->setStyle("fontWeight","bold");
      $this->setStyle("lineHeight","24px");
      $this->setStyle("cursor","pointer");
    }
  }

?>